refactor: migrate avoid_unused_parameters#290
Conversation
There was a problem hiding this comment.
Code Review
This pull request refactors the avoid_unused_parameters lint rule to align with the new SolidLintRule API, replacing custom lint builder APIs with RuleVisitorRegistry and RuleContext. It also introduces comprehensive unit tests and a fake analysis options loader for testing. Feedback on the changes highlights a potential issue in visitFunctionExpression where anonymous functions defined inside excluded methods or constructors are not correctly ignored, which could lead to false positives. A suggestion was provided to check for any enclosing executable declaration to resolve this.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
removes
LintCodeCopyWithso the tests can compile, can be re-added laterimproves code comments
adds
FakeAnalysisOptionsLoaderto help in testing